g_return_if_fail() is the cell is not part of the combo instead of
authorMichael Natterer <mitch@imendio.com>
Mon, 4 Feb 2008 23:01:00 +0000 (23:01 +0000)
committerMichael Natterer <mitch@src.gnome.org>
Mon, 4 Feb 2008 23:01:00 +0000 (23:01 +0000)
2008-02-04  Michael Natterer  <mitch@imendio.com>

* gtk/gtkcombobox.c (gtk_combo_box_cell_layout_add_attribute):
g_return_if_fail() is the cell is not part of the combo instead of
crashing in the next line.

svn path=/trunk/; revision=19462

ChangeLog
gtk/gtkcombobox.c

index e7d1d0833459910fb7b1cc290fd877777b4cfb57..00fca272a6f89d7c96e2b304b3e78c5e5b0f2477 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2008-02-04  Michael Natterer  <mitch@imendio.com>
+
+       * gtk/gtkcombobox.c (gtk_combo_box_cell_layout_add_attribute):
+       g_return_if_fail() is the cell is not part of the combo instead of
+       crashing in the next line.
+
 2008-02-01  Cody Russell  <cody@jhu.edu>
 
        * modules/engines/ms-windows/xp_theme.[ch]
index 7021e716010e175bafb76caf5fc403d6389a3ee0..c1f9156041a4974fca1fc9daa75cbe85a0742ed0 100644 (file)
@@ -4264,6 +4264,7 @@ gtk_combo_box_cell_layout_add_attribute (GtkCellLayout   *layout,
   combo_box = GTK_COMBO_BOX (layout);
 
   info = gtk_combo_box_get_cell_info (combo_box, cell);
+  g_return_if_fail (info != NULL);
 
   info->attributes = g_slist_prepend (info->attributes,
                                       GINT_TO_POINTER (column));